* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
a{
    text-decoration: none;
}

body {
    background-color: #f5f5f5;
    font-family: Arial, sans-serif;
}

.header {
    background-color: white;
    padding: 15px 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.header-content {
    width: 1200px;
    border: 1px solid green;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    color: #ff0036;
    font-size: 24px;
    font-weight: bold;
    font-family: 'STXingkai', '华文行楷', cursive;
}

.search-box {
    display: flex;
    align-items: center;
    width: 600px;
}

.search-input {
    flex: 1;
    height: 40px;
    padding: 0 15px;
    border: 2px solid #ff0036;
    border-radius: 4px 0 0 4px;
    font-size: 14px;
}

.search-btn {
    width: 80px;
    height: 40px;
    background-color: #ff0036;
    color: white;
    border: none;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    font-size: 16px;
}

.user-actions {
    list-style: none;
}
.user-actions>li{
    float: left;
    width: 120px;
    text-align: center;
    border-right: 1px solid #ff0036;

}
.user-actions li a{
    display: block;
    color: #666;
    font-size: 14px;
}


.user-actions li a:hover {
    color: #ff0036;
}
.user-actions li:last-child{
    cursor: pointer;
    border: none;
    position: relative;

}
.downlist{
    display: none;
    width: 100%;
    position: absolute;
    list-style: none;
    background-color: white;
    text-align: center;
    left: 18px;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.downlist>li{
    width: 100%;
    height: 35px;
    line-height: 30px;
    margin-top: 5px;
}
.downlist li a{
    border-bottom: 2px solid #f5f5f5;
    display: block; 
}
.user-actions li:last-child:hover .downlist{
    display: block;
}
.downlist li:hover{
    background-color: #f5f5f5;
    color: #ff0036;
}

.clear{
    clear: both;
}
.clearfix::after{
    content: "";
    clear: both;
    display: block;
}


.main-content {
    width: 1200px;
    margin: 20px auto;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.product-card {
    background: white;
    border-radius: 4px;
    padding: 10px;
    transition: transform 0.3s;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.product-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    /* overflow: hidden; */
    border-radius: 4px;
}

.product-title {
    margin: 10px 0;
    font-size: 14px;
    color: #333;
    height: 40px;
    overflow-x: hidden;
}

.product-price {
    color: #ff0036;
    font-size: 20px;
    font-weight: bold;
}

.product-price::before {
    content: '¥';
    font-size: 14px;
}



.category-nav {
    width: 1200px;
    margin: 20px auto;
    background: white;
    border-radius: 4px;
    padding: 15px 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.category-list {
    display: flex;
    list-style: none;
    padding: 0 20px;
}

.category-item {
    padding: 0 25px;
    position: relative;
}

.category-item:not(:last-child)::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 14px;
    background-color: #ddd;
}

.category-item a {
    color: #333;
    font-size: 16px;
}

.category-item a:hover {
    color: #ff0036;
}

.category-item.active a {
    color: #ff0036;
    font-weight: bold;
}